Disk drives are commonly used to store data in computers, data bases, digital video recorders, and other devices. A disk drive comprises a rotating magnetic disk and a head actuated over the disk to magnetically write data to and read data from the disk. The disk drive may write data to and read data from the disk in response to write/read commands from a host that uses the disk drive for data storage. Typically, the host addresses data stored in the disk drive using logical addresses. The disk drive maintains a mapping table mapping the logical addresses from the host to physical addresses of the corresponding data on the disk. When the host later requests data from the disk drive at certain logical addresses, the disk drive uses the mapping table to locate the requested data on the disk.
The disk drive may update the mapping table in a buffer as the disk drive writes data from the host to the disk. The disk drive may later write the updated mapping table in the buffer to the disk for later use. However, the disk drive may be not write the updated mapping table to the disk, for example, due to power lose or other reason. Therefore, it is desirable for the disk drive to be able to quickly reconstruct the updated mapping table.